// default package

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * Quanxian entity.
 * 
 * @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "quanxian", catalog = "hibernate")
public class Quanxian implements java.io.Serializable {

	// Fields

	private Integer id;
	private User user;
	private String quanxianname;

	// Constructors

	/** default constructor */
	public Quanxian() {
	}

	/** full constructor */
	public Quanxian(User user, String quanxianname) {
		this.user = user;
		this.quanxianname = quanxianname;
	}

	// Property accessors
	@Id
	@GeneratedValue
	@Column(name = "id", unique = true, nullable = false)
	public Integer getId() {
		return this.id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "user_id")
	public User getUser() {
		return this.user;
	}

	public void setUser(User user) {
		this.user = user;
	}

	@Column(name = "quanxianname")
	public String getQuanxianname() {
		return this.quanxianname;
	}

	public void setQuanxianname(String quanxianname) {
		this.quanxianname = quanxianname;
	}

}